<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<!doctype html>
<html lang="en">
<head>
    <%@include file="/WEB-INF/pages/common/head.jsp"%>
    <style>
        body{
            background: #2C4257;
            color:#fff;
        }
    </style>
</head>
<body>
<div class="container">
    <div class="row">
        <!-- 循环菜单 -->
        <div class="col-md-6">
            <div id="sidebar-menu" class="main_menu_side hidden-print main_menu">

                <div class="menu_section">
                    <h3>菜单</h3>
                    <ul class="nav side-menu">
                        <c:forEach items="${menus}" var="entry">
                            <li><a> ${entry.menuName} <span class="fa fa-chevron-down"></span></a>
                                <ul class="nav child_menu">
                                    <c:forEach var="m2" items="${entry.children}">
                                        <li><a target="content" onclick="searchByMenu(${m2.menuNum})">${m2.menuName}</a></li>
                                    </c:forEach>

                                </ul>
                            </li>
                        </c:forEach>

                    </ul>
                </div>
            </div>
        </div>
        <!-- 进行赋值 -->
        <div class="col-md-6" id="menu">
            <form action="" id="upMenu">
                <div class="row">
                    <div class="col-md-6">
                        <label>菜单名称:</label>
                        <input type="text" name="menuName" class="form-control">
                        <input type="hidden" name="menuId" class="form-control">
                    </div>
                    <div class="col-md-6">
                        <label>父级编码:</label>
                        <input type="text" name="menuParent" class="form-control">
                    </div>
                </div>
                <div class="row">
                    <div class="col-md-6">
                        <label>菜单编号:</label>
                        <input type="text" name="menuNum" class="form-control">
                    </div>
                    <div class="col-md-6">
                        <label>菜单序号:</label>
                        <input type="text" name="menuSer" class="form-control">
                    </div>
                </div>
                <div class="row">
                    <div class="col-md-6">
                        <label>菜单标识:</label>
                        <input type="text" name="menuIde" class="form-control">
                    </div>
                    <div class="col-md-6">
                        <label>是否可用:</label><br>
                        <select name="menuStatus" class="form-control">
                            <option value="0">在用</option>
                            <option value="1">禁用</option>
                        </select>
                    </div>
                </div>
                <div class="row">
                    <div class="col-md-12">
                        <label>菜单描述:</label>
                        <input type="text" name="menuDesc" class="form-control">
                    </div>
                </div>
                <div class="row">
                    <div class="col-md-12">
                        <label>菜单url:</label>
                        <input type="text" name="menuUrl" class="form-control">
                    </div>
                </div>
                <br>
                <div class="row">
                    <div class="col-md-9" >
                    </div>
                    <div class="col-md-2" >
                        <button type="button" onclick="updateMenu()" class="btn right btn-success">保存</button>
                    </div>
                </div>
            </form>
        </div>
    </div>
</div>
<%@include file="/WEB-INF/pages/common/modal.jsp"%>
<script src="res/js/menu.js"></script>
</body>
</html>